package com.wavercaz.freeforum.services.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.wavercaz.freeforum.mappers.PostMapper;
import com.wavercaz.freeforum.pojo.CommonSearchParam;
import com.wavercaz.freeforum.pojo.Post;
import com.wavercaz.freeforum.services.PostService;
import com.wavercaz.freeforum.pojo.vo.PostVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class PostServiceImpl extends ServiceImpl<PostMapper,Post> implements PostService {

    @Autowired
    private PostMapper postMapper;

    @Override
    public IPage<PostVo> getPostVoList(CommonSearchParam commonSearchParam, Page<PostVo> page) {
        return postMapper.getPostVoList(commonSearchParam,page);
    }
}
